function mineReadFile(path) {
    return new Promise((resolve, reject) => {
        require('fs').readFile(path, (err, data) => {
            console.log(path, err, data)
            if (err) reject(err)
            resolve(data.toString())
        })
    })
}

mineReadFile('./resource/content.txt').then(value => {
    console.log(value);
}, reason => {
    console.log(reason);
})